<html>
  <head>
    <META http-equiv="Content-Type" content="text/html; charset=utf-8">
    <link rel="stylesheet" type="text/css" href="..\..\..\JavaDoc.css">
  </head>
  <body>
    <table class="nav">
      <tr>
        <td class="nav1" colspan="2">
          <table cellspacing="3">
            <tr>
              <td>
                <a href="..\..\..\overview-summary.html"> Overview </a>
              </td>
              <td>
                <a href="namespace-summary.html">Namespace</a> </td>
              <td class="nav1sel"> Type </td>
              <td>Use </td>
              <td>Tree </td>
              <td>Deprecated </td>
              <td>Index </td>
              <td>Help </td>
            </tr>
          </table>
        </td>
        <td class="logo" rowspan="2">.NET Framework</td>
      </tr>
      <tr class="nav2">
        <td>PREV TYPE    NEXT TYPE</td>
        <td>FRAMES    NO FRAMES</td>
      </tr>
      <tr class="nav2">
        <td>SUMMARY: INNER | FIELD | CONST | <a href="#property-summary">PROP</a> | <a href="#method-summary">METHOD</a> | OP | EVENT</td>
        <td>DETAIL: FIELD | CONST | <a href="#property-detail">PROP</a> | <a href="#method-detail">METHOD</a> | OP | EVENT</td>
      </tr>
    </table>
    <hr>
    <h2>
      <span class="namespaceName">NVelocity.Runtime.Parser</span>
      <br>
      <span class="className">Interface CharStream</span>
    </h2>
    <p> This interface describes a character stream that maintains line and
            column number positions of the characters.  It also has the capability
            to backup the stream to some extent.  An implementation of this
            interface is used in the TokenManager implementation generated by
            JavaCCParser.
            
            All the methods except backup can be implemented in any fashion. backup
            needs to be implemented correctly for the correct operation of the lexer.
            Rest of the methods are all used to get information like line number,
            column number and the String that constitutes a token and are not used
            by the lexer. Hence their implementation won't affect the generated lexer's
            operation.
            </p>
    <a name="field-summary">
    </a>
    <a name="constructor-summary">
    </a>
    <a name="property-summary">
    </a>
    <table class="table" cellspacing="0">
      <thead>
        <tr>
          <th colspan="2">Property Summary</th>
        </tr>
      </thead>
      <tr>
        <td class="propertyType" valign="top">int</td>
        <td class="property">
          <a href="#NVelocity.Runtime.Parser.CharStream.BeginColumn">BeginColumn</a>
        </td>
      </tr>
      <tr>
        <td class="propertyType" valign="top">int</td>
        <td class="property">
          <a href="#NVelocity.Runtime.Parser.CharStream.BeginLine">BeginLine</a>
        </td>
      </tr>
      <tr>
        <td class="propertyType" valign="top">int</td>
        <td class="property">
          <a href="#NVelocity.Runtime.Parser.CharStream.Column">Column</a>
        </td>
      </tr>
      <tr>
        <td class="propertyType" valign="top">int</td>
        <td class="property">
          <a href="#NVelocity.Runtime.Parser.CharStream.EndColumn">EndColumn</a>
        </td>
      </tr>
      <tr>
        <td class="propertyType" valign="top">int</td>
        <td class="property">
          <a href="#NVelocity.Runtime.Parser.CharStream.EndLine">EndLine</a>
        </td>
      </tr>
      <tr>
        <td class="propertyType" valign="top">int</td>
        <td class="property">
          <a href="#NVelocity.Runtime.Parser.CharStream.Line">Line</a>
        </td>
      </tr>
    </table>
    <br>
    <a name="method-summary">
    </a>
    <table class="table" cellspacing="0">
      <thead>
        <tr>
          <th colspan="2">Method Summary</th>
        </tr>
      </thead>
      <tr>
        <td class="returnType" valign="top">void</td>
        <td class="method">
          <a href="#NVelocity.Runtime.Parser.CharStream.backup(System.Int32)">backup</a>(int amount)<br>         Returns the column position of the character last read.
             Returns the line number of the character last read.
             Returns the column number of the last character for current token (being
            matched after the last call to BeginTOken).
             Returns the line number of the last character for current token (being
            matched after the last call to BeginTOken).
             Returns the column number of the first character for current token (being
            matched after the last call to BeginTOken).
             Returns the line number of the first character for current token (being
            matched after the last call to BeginTOken).
             Backs up the input stream by amount steps. Lexer calls this method if it
            had already read some characters, but could not use them to match a
            (longer) token. So, they will be used again as the prefix of the next
            token and it is the implemetation's responsibility to do this right.
            </td>
      </tr>
      <tr>
        <td class="returnType" valign="top">char</td>
        <td class="method">
          <a href="#NVelocity.Runtime.Parser.CharStream.BeginToken">BeginToken</a>()<br>         Returns the next character that marks the beginning of the next token.
            All characters must remain in the buffer between two successive calls
            to this method to implement backup correctly.
            </td>
      </tr>
      <tr>
        <td class="returnType" valign="top">void</td>
        <td class="method">
          <a href="#NVelocity.Runtime.Parser.CharStream.Done">Done</a>()<br>         The lexer calls this function to indicate that it is done with the stream
            and hence implementations can free any resources held by this class.
            Again, the body of this function can be just empty and it will not
            affect the lexer's operation.
            </td>
      </tr>
      <tr>
        <td class="returnType" valign="top">string</td>
        <td class="method">
          <a href="#NVelocity.Runtime.Parser.CharStream.GetImage">GetImage</a>()<br>         Returns a string made up of characters from the marked token beginning
            to the current buffer position. Implementations have the choice of returning
            anything that they want to. For example, for efficiency, one might decide
            to just return null, which is a valid implementation.
            </td>
      </tr>
      <tr>
        <td class="returnType" valign="top">char[]</td>
        <td class="method">
          <a href="#NVelocity.Runtime.Parser.CharStream.GetSuffix(System.Int32)">GetSuffix</a>(int len)<br>         Returns an array of characters that make up the suffix of length 'len' for
            the currently matched token. This is used to build up the matched string
            for use in actions in the case of MORE. A simple and inefficient
            implementation of this is as follows :
            
            {
            String t = GetImage();
            return t.substring(t.length() - len, t.length()).toCharArray();
            }
            </td>
      </tr>
      <tr>
        <td class="returnType" valign="top">char</td>
        <td class="method">
          <a href="#NVelocity.Runtime.Parser.CharStream.readChar">readChar</a>()<br>         Returns the next character from the selected input.  The method
            of selecting the input is the responsibility of the class
            implementing this interface.  Can throw any java.io.IOException.
            </td>
      </tr>
    </table>
    <br>
    <a name="operator-summary">
    </a>
    <a name="event-summary">
    </a>
    <br>
    <a name="field-detail">
    </a>
    <a name="constructor-detail">
    </a>
    <a name="property-detail">
    </a>
    <table class="table" cellspacing="0">
      <thead>
        <tr>
          <th>Property Detail</th>
        </tr>
      </thead>
    </table>
    <a name="NVelocity.Runtime.Parser.CharStream.BeginColumn">
    </a>
    <h3>BeginColumn</h3>
    <pre>public int BeginColumn</pre>
    <dl>
      <dd>
        <p>
        </p>
        <p>
        </p>
      </dd>
    </dl>
    <hr>
    <a name="NVelocity.Runtime.Parser.CharStream.BeginLine">
    </a>
    <h3>BeginLine</h3>
    <pre>public int BeginLine</pre>
    <dl>
      <dd>
        <p>
        </p>
        <p>
        </p>
      </dd>
    </dl>
    <hr>
    <a name="NVelocity.Runtime.Parser.CharStream.Column">
    </a>
    <h3>Column</h3>
    <pre>public int Column</pre>
    <dl>
      <dd>
        <p>
        </p>
        <p>
        </p>
      </dd>
    </dl>
    <hr>
    <a name="NVelocity.Runtime.Parser.CharStream.EndColumn">
    </a>
    <h3>EndColumn</h3>
    <pre>public int EndColumn</pre>
    <dl>
      <dd>
        <p>
        </p>
        <p>
        </p>
      </dd>
    </dl>
    <hr>
    <a name="NVelocity.Runtime.Parser.CharStream.EndLine">
    </a>
    <h3>EndLine</h3>
    <pre>public int EndLine</pre>
    <dl>
      <dd>
        <p>
        </p>
        <p>
        </p>
      </dd>
    </dl>
    <hr>
    <a name="NVelocity.Runtime.Parser.CharStream.Line">
    </a>
    <h3>Line</h3>
    <pre>public int Line</pre>
    <dl>
      <dd>
        <p>
        </p>
        <p>
        </p>
      </dd>
    </dl>
    <a name="method-detail">
    </a>
    <table class="table" cellspacing="0">
      <thead>
        <tr>
          <th>Method Detail</th>
        </tr>
      </thead>
    </table>
    <a name="NVelocity.Runtime.Parser.CharStream.backup(System.Int32)">
    </a>
    <h3>backup</h3>
    <pre>public void backup(int amount)</pre>
    <dl>
      <dd>
        <p> Returns the column position of the character last read.
             Returns the line number of the character last read.
             Returns the column number of the last character for current token (being
            matched after the last call to BeginTOken).
             Returns the line number of the last character for current token (being
            matched after the last call to BeginTOken).
             Returns the column number of the first character for current token (being
            matched after the last call to BeginTOken).
             Returns the line number of the first character for current token (being
            matched after the last call to BeginTOken).
             Backs up the input stream by amount steps. Lexer calls this method if it
            had already read some characters, but could not use them to match a
            (longer) token. So, they will be used again as the prefix of the next
            token and it is the implemetation's responsibility to do this right.
            </p>
        <p>
        </p>
      </dd>
    </dl>
    <hr>
    <a name="NVelocity.Runtime.Parser.CharStream.BeginToken">
    </a>
    <h3>BeginToken</h3>
    <pre>public char BeginToken()</pre>
    <dl>
      <dd>
        <p> Returns the next character that marks the beginning of the next token.
            All characters must remain in the buffer between two successive calls
            to this method to implement backup correctly.
            </p>
        <p>
        </p>
      </dd>
    </dl>
    <hr>
    <a name="NVelocity.Runtime.Parser.CharStream.Done">
    </a>
    <h3>Done</h3>
    <pre>public void Done()</pre>
    <dl>
      <dd>
        <p> The lexer calls this function to indicate that it is done with the stream
            and hence implementations can free any resources held by this class.
            Again, the body of this function can be just empty and it will not
            affect the lexer's operation.
            </p>
        <p>
        </p>
      </dd>
    </dl>
    <hr>
    <a name="NVelocity.Runtime.Parser.CharStream.GetImage">
    </a>
    <h3>GetImage</h3>
    <pre>public string GetImage()</pre>
    <dl>
      <dd>
        <p> Returns a string made up of characters from the marked token beginning
            to the current buffer position. Implementations have the choice of returning
            anything that they want to. For example, for efficiency, one might decide
            to just return null, which is a valid implementation.
            </p>
        <p>
        </p>
      </dd>
    </dl>
    <hr>
    <a name="NVelocity.Runtime.Parser.CharStream.GetSuffix(System.Int32)">
    </a>
    <h3>GetSuffix</h3>
    <pre>public char[] GetSuffix(int len)</pre>
    <dl>
      <dd>
        <p> Returns an array of characters that make up the suffix of length 'len' for
            the currently matched token. This is used to build up the matched string
            for use in actions in the case of MORE. A simple and inefficient
            implementation of this is as follows :
            
            {
            String t = GetImage();
            return t.substring(t.length() - len, t.length()).toCharArray();
            }
            </p>
        <p>
        </p>
      </dd>
    </dl>
    <hr>
    <a name="NVelocity.Runtime.Parser.CharStream.readChar">
    </a>
    <h3>readChar</h3>
    <pre>public char readChar()</pre>
    <dl>
      <dd>
        <p> Returns the next character from the selected input.  The method
            of selecting the input is the responsibility of the class
            implementing this interface.  Can throw any java.io.IOException.
            </p>
        <p>
        </p>
      </dd>
    </dl>
    <a name="operator-detail">
    </a>
    <a name="event-detail">
    </a>
    <hr>
    <table class="nav">
      <tr>
        <td class="nav1" colspan="2">
          <table cellspacing="3">
            <tr>
              <td>
                <a href="..\..\..\overview-summary.html"> Overview </a>
              </td>
              <td>
                <a href="namespace-summary.html">Namespace</a> </td>
              <td class="nav1sel"> Type </td>
              <td>Use </td>
              <td>Tree </td>
              <td>Deprecated </td>
              <td>Index </td>
              <td>Help </td>
            </tr>
          </table>
        </td>
        <td class="logo" rowspan="2">.NET Framework</td>
      </tr>
      <tr class="nav2">
        <td>PREV TYPE    NEXT TYPE</td>
        <td>FRAMES    NO FRAMES</td>
      </tr>
      <tr class="nav2">
        <td>SUMMARY: INNER | FIELD | CONST | <a href="#property-summary">PROP</a> | <a href="#method-summary">METHOD</a> | OP | EVENT</td>
        <td>DETAIL: FIELD | CONST | <a href="#property-detail">PROP</a> | <a href="#method-detail">METHOD</a> | OP | EVENT</td>
      </tr>
    </table>
  </body>
</html>